package com.dt.sns.config;

import org.springframework.context.annotation.Configuration;
import org.springframework.web.servlet.config.annotation.InterceptorRegistry;
import org.springframework.web.servlet.config.annotation.WebMvcConfigurerAdapter;

import com.dt.sns.core.interceptor.InitInterceptor;
import com.dt.sns.core.interceptor.LoggerInterceptor;

@Configuration
public class WebMvcConfigurer extends WebMvcConfigurerAdapter {

	public void addInterceptors(InterceptorRegistry registry) {
		registry.addInterceptor(new LoggerInterceptor()).addPathPatterns("/**");
		registry.addInterceptor(new InitInterceptor()).addPathPatterns("/**");
	}
}